export default class Resources {
    static load(path: string) {
        return new Promise(function (resolve, reject) {
            cc.resources.load(path, function (err, asset) {
                if (err) {
                    console.error(err)
                    reject(asset)
                } else {
                    resolve(asset)
                }
            })
        })
    }
}
